package cn.wizzer.app.crown.modules.services;

import cn.wizzer.app.crown.modules.models.CrownBet;
import cn.wizzer.app.crown.modules.models.CrownMatch;
import cn.wizzer.app.crown.modules.models.enums.BetsEnum;
import cn.wizzer.framework.base.service.BaseService;

import java.util.List;

public interface CrownBetService extends BaseService<CrownBet> {

    /**
     * 修改赛事投资利率、保本
     *
     * @param match
     */
    void editDo(CrownMatch match);

    /**
     * 查询赛事关联的bets(有缓存查缓存)
     *
     * @param matchId
     * @param betType
     * @param orderBy
     * @return
     */
    List<CrownBet> queryBets(String matchId, BetsEnum betType, String orderBy);

    /**
     * 删除指定赛事、bet类型缓存
     */
    void clearCache(String matchId, BetsEnum betType);


    /**
     * 删除指定赛事缓存
     */
    void clearCache(String matchId);


    /**
     * 删除全部缓存
     */
    void clearCacheAll();
}
